module.exports = {
  detail: function (e) {
    wx.navigateTo({
      url: `../product/detail?id=${e.currentTarget.dataset.id}`
    });
  },
  more: function (e) {
    let param = e.currentTarget.dataset.param || '',
        value = e.currentTarget.dataset.value || '';
    wx.navigateTo({
      url: `../product/index?param=${param}&val=${value}`
    });
  },
  similar: function (keyword) {
    wx.navigateTo({
      url: `../product/index?keyword=${keyword}`
    });
  }
}